package com.fckbug.action.question;

import java.util.List;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.apache.struts.action.Action;
import org.apache.struts.action.ActionForm;
import org.apache.struts.action.ActionForward;
import org.apache.struts.action.ActionMapping;

import com.fckbug.service.QAService;
import com.fckbug.util.SpringContextHolder;

/**
 * 未解决的问题
 * @author think
 *
 */
public class UnAnsweredQAction extends Action {
	QAService qaService = (QAService)SpringContextHolder.getBean("qaService");
	public ActionForward execute(ActionMapping mapping, ActionForm form,
            HttpServletRequest request, HttpServletResponse response) throws Exception {
		List result = qaService.getUnAnsweredQ(0);
		request.setAttribute("result", result);
		return mapping.findForward("success");
	}
}
